
<!-- Inicio codigo para el Google MAPS -->
<%= stylesheet_link_tag 'gmaps4rails' %>
<!-- Fin codigo para el Google MAPS -->
<% if flash[:notice] %>
    <div id="notice"><%= flash[:notice] %></div>
<% end %>
<h1>Mostrar Pre Registro</h1>
<!-- Inicio Bloque de la izquierda -->
<div class="shadow">
<fieldset >
  <fieldset id="agrupacion" >
      <legend>Datos Básicos </legend>
      <fieldset class="column-left3" >
        <%if !@cultural_heritage_cultural_heritage_pre_register.preRegisterRegistrationCode.blank?%>
        <p>
          <b>Código de Pre Registro Nacional:</b>
            <%= @cultural_heritage_cultural_heritage_pre_register.preRegisterRegistrationCode %>
        </p>
        <%end%>
        <%if !@cultural_heritage_cultural_heritage_pre_register.name.blank?%>
        <p>
          <b>Nombre:</b>
            <%= @cultural_heritage_cultural_heritage_pre_register.name %>
        </p>
        <%end%>
        <%if !@cultural_heritage_cultural_heritage_pre_register.description.blank?%>
        <p>
          <b>Descripción:</b>
            <%= @cultural_heritage_cultural_heritage_pre_register.description %>
        </p>
        <%end%>
      </fieldset>

  </fieldset>
  <br />
  <% if !(@cultural_heritage_cultural_heritage_pre_register.height.blank? and @cultural_heritage_cultural_heritage_pre_register.long.blank? and @cultural_heritage_cultural_heritage_pre_register.width.blank? and @cultural_heritage_cultural_heritage_pre_register.weight.blank?) %>
  <fieldset id="agrupacion">
      <legend>Medidas</legend>
      <fieldset class="column-left">
        <%if !@cultural_heritage_cultural_heritage_pre_register.height.blank?%>
        <p>
          <b>Alto:</b>
            <%= @cultural_heritage_cultural_heritage_pre_register.height %> cm
        </p>
        <%end%>
        <%if !@cultural_heritage_cultural_heritage_pre_register.long.blank?%>
        <p>
          <b>Largo:</b>
            <%= @cultural_heritage_cultural_heritage_pre_register.long %> cm
        </p>
        <%end%>
      </fieldset>
      <fieldset class="column-right">
        <%if !@cultural_heritage_cultural_heritage_pre_register.width.blank?%>
        <p>
          <b>Ancho:</b>
            <%= @cultural_heritage_cultural_heritage_pre_register.width %> cm
        </p>
        <%end%>
        <%if !@cultural_heritage_cultural_heritage_pre_register.weight.blank?%>
        <p>
          <b>Peso:</b>
            <%= @cultural_heritage_cultural_heritage_pre_register.weight %> kg
        </p>
        <%end%>
      </fieldset>
  </fieldset>
  <br />
  <%end%>
  <% if !(@cultural_heritage_cultural_heritage_pre_register.conservationalState.blank? and @cultural_heritage_cultural_heritage_pre_register.integrityState.blank?) %>
  <fieldset id="agrupacion">
    <legend>Manejo de Estados</legend>
    <%if !@cultural_heritage_cultural_heritage_pre_register.conservationalState.blank?%>
    <p>
      <b>Estado de Conservación:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_conservational_state.name,{:controller=>"/cultural_heritage/conservational_states",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_conservational_state.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_conservational_state.description%>
        <%#= @cultural_heritage_cultural_heritage.obj_conservational_state.name %>
    </p>
    <%end%>
    <%if !@cultural_heritage_cultural_heritage_pre_register.integrityState.blank?%>
    <p>
      <b>Estado de Integridad:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_integrity_state.name,{:controller=>"/cultural_heritage/integrity_states",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_integrity_state.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_integrity_state.description%>
        <%#= @cultural_heritage_cultural_heritage.obj_integrity_state.name %>
    </p>
    <%end%>
  </fieldset>
  <br/>
  <%end%>
  <fieldset id="agrupacion">
    <legend>Agrupaciones</legend>
    <fieldset class="column-left">
      <%if !@cultural_heritage_cultural_heritage_pre_register.group.blank?%>
      <p>
        <b>Grupo:</b>
          <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_group.name,{:controller=>"/cultural_heritage/groups",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_group.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_group.description%>
      </p>
      <%end%>
      <%if !@cultural_heritage_cultural_heritage_pre_register.subGroup.blank?%>
      <p>
        <b>Subgrupo:</b>
          <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_subGroup.name,{:controller=>"/cultural_heritage/sub_groups",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_subGroup.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_subGroup.description%>
      </p>
      <%end%>
      <%if !@cultural_heritage_cultural_heritage_pre_register.tipology.blank?%>
      <p>
        <b>Tipología:</b>
          <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_tipology.name,{:controller=>"/cultural_heritage/tipologies",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_tipology.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_tipology.description%>
      </p>
      <%end%>
      <%if !@cultural_heritage_cultural_heritage_pre_register.typeCulturalInstitution.blank?%>
      <p>
        <b>Tipo de Institución Cultural:</b>
          <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_typeCulturalInstitution.name,{:controller=>"/cultural_heritage/type_cultural_institutions",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_typeCulturalInstitution.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_typeCulturalInstitution.description%>
          <%#= @cultural_heritage_cultural_heritage.obj_typeCulturalInstitution.name %>
      </p>
      <%end%>
    </fieldset>
    <fieldset class="column-right">
      <%if !@cultural_heritage_cultural_heritage_pre_register.culturalInstitution.blank?%>
      <%if @cultural_heritage_cultural_heritage_pre_register.typeCulturalInstitution == 1%>
      <p>
        <b>Institución Cultural:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_culturalInstitution.name,{:controller=>"/cultural_heritage/cultural_institutions",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_culturalInstitution.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_culturalInstitution.description%>
          <%#= @cultural_heritage_cultural_heritage.obj_culturalInstitution.name %>
      </p>
      <%end%>
      <%if @cultural_heritage_cultural_heritage_pre_register.typeCulturalInstitution == 2%>
      <p>
        <b>Patrimonio Cultural:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_cultural_heritage.name,{:controller=>"/cultural_heritage/cultural_heritage_properties",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_cultural_heritage.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_cultural_heritage.description%>
          <%#= @cultural_heritage_cultural_heritage.obj_culturalInstitution.name %>
      </p>
      <%end%>
      <%end%>
      <%if !@cultural_heritage_cultural_heritage_pre_register.period.blank?%>
      <p>
        <b>Periodo:</b>
          <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_period.name,{:controller=>"/cultural_heritage/periods",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_period.id}%>
      </p>
      <%end%>
      <%if !@cultural_heritage_cultural_heritage_pre_register.culture.blank?%>
      <p>
        <b>Cultura:</b>
          <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_culture.name,{:controller=>"/cultural_heritage/cultures",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_culture.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_culture.description%>
      </p>
      <%end%>
      <%if !@cultural_heritage_cultural_heritage_pre_register.style.blank?%>
      <p>
        <b>Estilo:</b>
          <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_style.name,{:controller=>"/cultural_heritage/styles",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_style.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_style.description%>
      </p>
      <%end%>
    </fieldset>
  </fieldset>
  <br/>
  <% if !(@cultural_heritage_cultural_heritage_pre_register.owner.blank? and @cultural_heritage_cultural_heritage_pre_register.author.blank?) %>
  <fieldset id="agrupacion">
    <legend>Autores</legend>
    <%if !@cultural_heritage_cultural_heritage_pre_register.owner.blank?%>
    <p>
      <b>Dueño:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_owner.name,{:controller=>"/security/people",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_owner.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_owner.email%>
    </p>
    <%end%>
    <%if !@cultural_heritage_cultural_heritage_pre_register.author.blank?%>
    <p>
      <b>Autor:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_author.name,{:controller=>"/security/people",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_author.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_author.email%>
    </p>
    <%end%>
  </fieldset>
  <br/>
  <%end%>
  <% if !(@cultural_heritage_cultural_heritage_pre_register.shape.blank? and @cultural_heritage_cultural_heritage_pre_register.technique.blank? and @cultural_heritage_cultural_heritage_pre_register.materials.blank?) %>
  <fieldset id="agrupacion">
     <legend>Datos Adicionales</legend>
     <fieldset class="column-left" >
    <%if !@cultural_heritage_cultural_heritage_pre_register.materials.blank?%>
     <p>
      <b>Materiales:</b>
        <%= @cultural_heritage_cultural_heritage_pre_register.materials %>
     </p>
     <%end%>
    </fieldset>
     <fieldset class="column-right" >
     <%if !@cultural_heritage_cultural_heritage_pre_register.shape.blank?%>
     <p>
      <b>Forma:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_shape.name,{:controller=>"/cultural_heritage/shapes",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_shape.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_shape.description%>
    </p>
    <%end%>
    <%if !@cultural_heritage_cultural_heritage_pre_register.technique.blank?%>
    <p>
      <b>Técnica:</b>
        <%= link_to @cultural_heritage_cultural_heritage_pre_register.obj_technique.name,{:controller=>"/cultural_heritage/techniques",:action => 'show',:id => @cultural_heritage_cultural_heritage_pre_register.obj_technique.id},:title => @cultural_heritage_cultural_heritage_pre_register.obj_technique.description%>
    </p>
    <%end%>
    <%#if !@cultural_heritage_cultural_heritage.topic.blank?%>
    <%#*<p>%>
      <%#*<b>Topico:</b>%>
        <%#= link_to @cultural_heritage_cultural_heritage.obj_topic.name,{:controller=>"/cultural_heritage/topics",:action => 'show',:id => @cultural_heritage_cultural_heritage.obj_topic.id},:title => @cultural_heritage_cultural_heritage.obj_topic.description%>
    <%#*</p>%>
    <%#end%>
     </fieldset>
  </fieldset>
  <%end%>
</fieldset>

<div id="lineaform"></div>
<!-- Google Maps inicia aqui -->
<%if @cultural_heritage_cultural_heritage_pre_register.gmaps == true or @cultural_heritage_cultural_heritage_pre_register.obj_culturalInstitution.gmaps == true%>
<fieldset id="agrupacion">
  <legend>Ubicacion</legend>
    <%= gmaps({
      "map_options" => { "type" => "HYBRID", "center_longitude" => 180, "zoom" => 7, "auto_adjust" => true},
      "markers"     => { "data" => @json,
                         "options" => {"list_container" => "markers_list" }
                        }


    })%>
  <ul id="markers_list">  </ul>
  <div id="lineaform"></div>
  <% if ! @cultural_heritage_cultural_heritage_pre_register.address.blank? %>
    <p>
      <b>Direccion:</b>
      <%= @cultural_heritage_cultural_heritage_pre_register.address %>
    </p>
    <%end%>
</fieldset>
<div id="lineaform"></div>
<%end%>


<!-- Menu inferior-->
<br/>

 <%= link_to 'Editar',{:controller => "cultural_heritage/pre_register_requests", :action => "edit_pre_register",:id => @cultural_heritage_cultural_heritage_pre_register.id }%>
|
<%= link_to 'Regresar',{:controller => "cultural_heritage/pre_register_requests", :action => "edit",:id => @cultural_heritage_cultural_heritage_pre_register.cultural_heritage_pre_register_request_id  }%>
